home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2001 May / SGI IRIX Base Documentation 2001 May.iso / usr / share / catman / p_man / cat2 / standard / waitid.z / waitid
Encoding:
Text File  |  1998-10-20  |  5.9 KB  |  132 lines

  1.  
  2.  
  3.  
  4. wwwwaaaaiiiittttiiiidddd((((2222))))                                                            wwwwaaaaiiiittttiiiidddd((((2222))))
  5.  
  6.  
  7.  
  8. NNNNAAAAMMMMEEEE
  9.      _wwww_aaaa_iiii_tttt_iiii_dddd - wait for child process to change state
  10.  
  11. SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
  12.      _####_iiii_nnnn_cccc_llll_uuuu_dddd_eeee _<<<<_ssss_yyyy_ssss_////_tttt_yyyy_pppp_eeee_ssss_...._hhhh_>>>>
  13.      _####_iiii_nnnn_cccc_llll_uuuu_dddd_eeee _<<<<_wwww_aaaa_iiii_tttt_...._hhhh_>>>>
  14.      _iiii_nnnn_tttt _wwww_aaaa_iiii_tttt_iiii_dddd_((((_iiii_dddd_tttt_yyyy_pppp_eeee______tttt _iiii_dddd_tttt_yyyy_pppp_eeee_,,,, _iiii_dddd______tttt _iiii_dddd_,,,, _ssss_iiii_gggg_iiii_nnnn_ffff_oooo______tttt _****_iiii_nnnn_ffff_oooo_pppp_,,,, _iiii_nnnn_tttt _oooo_pppp_tttt_iiii_oooo_nnnn_ssss_))))_;;;;
  15.  
  16. DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  17.      _wwww_aaaa_iiii_tttt_iiii_dddd suspends the calling process until one of its children changes
  18.      state.  It records the current state of a child in the structure pointed
  19.      to by _i_n_f_o_p.  If a child process changed state prior to the call to
  20.      _wwww_aaaa_iiii_tttt_iiii_dddd, _wwww_aaaa_iiii_tttt_iiii_dddd returns immediately.
  21.  
  22.      The _i_d_t_y_p_e and _i_d arguments specify which children _wwww_aaaa_iiii_tttt_iiii_dddd is to wait for.
  23.  
  24.           If _i_d_t_y_p_e is _PPPP______PPPP_IIII_DDDD, _wwww_aaaa_iiii_tttt_iiii_dddd waits for the child with a process ID
  25.           equal to _((((_pppp_iiii_dddd______tttt_)))) _i_d.
  26.  
  27.           If _i_d_t_y_p_e is _PPPP______PPPP_GGGG_IIII_DDDD, _wwww_aaaa_iiii_tttt_iiii_dddd waits for any child with a process group
  28.           ID equal to _((((_pppp_iiii_dddd______tttt_))))_i_d.
  29.  
  30.           If _i_d_t_y_p_e is _PPPP______AAAA_LLLL_LLLL, _wwww_aaaa_iiii_tttt_iiii_dddd waits for any children and _i_d is ignored.
  31.  
  32.      The _o_p_t_i_o_n_s argument is used to specify which state changes _w_a_i_t_i_d is to
  33.      wait for.  It is formed by an OR of any of the following flags:
  34.  
  35.      _WWWW_EEEE_XXXX_IIII_TTTT_EEEE_DDDD        Wait for process(es) to exit.
  36.  
  37.      _WWWW_TTTT_RRRR_AAAA_PPPP_PPPP_EEEE_DDDD       Wait for traced process(es) to become trapped or reach a
  38.                     breakpoint (see _pppp_tttt_rrrr_aaaa_cccc_eeee(2)).
  39.  
  40.      _WWWW_SSSS_TTTT_OOOO_PPPP_PPPP_EEEE_DDDD       Wait for and return the process status of any child that
  41.                     has stopped upon receipt of a signal.
  42.  
  43.      _WWWW_CCCC_OOOO_NNNN_TTTT_IIII_NNNN_UUUU_EEEE_DDDD     Return the status for any child that was stopped and has
  44.                     been continued.
  45.  
  46.      _WWWW_NNNN_OOOO_HHHH_AAAA_NNNN_GGGG        Return immediately.
  47.  
  48.      _WWWW_NNNN_OOOO_WWWW_AAAA_IIII_TTTT        Keep the process in a waitable state.
  49.  
  50.      _i_n_f_o_p must point to a _ssss_iiii_gggg_iiii_nnnn_ffff_oooo______tttt structure, as defined in _ssss_iiii_gggg_iiii_nnnn_ffff_oooo(5).
  51.      _ssss_iiii_gggg_iiii_nnnn_ffff_oooo______tttt is filled in by the system with the status of the process being
  52.      waited for.
  53.  
  54.      _wwww_aaaa_iiii_tttt_iiii_dddd fails if one or more of the following is true.
  55.  
  56.      _EEEE_FFFF_AAAA_UUUU_LLLL_TTTT         _i_n_f_o_p points to an invalid address.
  57.  
  58.  
  59.  
  60.  
  61.                                                                         PPPPaaaaggggeeee 1111
  62.  
  63.  
  64.  
  65.  
  66.  
  67.  
  68. wwwwaaaaiiiittttiiiidddd((((2222))))                                                            wwwwaaaaiiiittttiiiidddd((((2222))))
  69.  
  70.  
  71.  
  72.      _EEEE_IIII_NNNN_TTTT_RRRR          _wwww_aaaa_iiii_tttt_iiii_dddd was interrupted due to the receipt of a signal by
  73.                     the calling process.
  74.  
  75.      _EEEE_IIII_NNNN_VVVV_AAAA_LLLL         An invalid value was specified for _o_p_t_i_o_n_s.
  76.  
  77.      _EEEE_IIII_NNNN_VVVV_AAAA_LLLL         _i_d_t_y_p_e and _i_d specify an invalid set of processes.
  78.  
  79.      _EEEE_CCCC_HHHH_IIII_LLLL_DDDD         The set of processes specified by _i_d_t_y_p_e and _i_d does not
  80.                     contain any unwaited-for processes.
  81.  
  82. DDDDIIIIAAAAGGGGNNNNOOOOSSSSTTTTIIIICCCCSSSS
  83.      If _wwww_aaaa_iiii_tttt_iiii_dddd returns due to a change of state of one of its children, a
  84.      value of 0 is returned.  Otherwise, a value of -1 is returned and _eeee_rrrr_rrrr_nnnn_oooo
  85.      is set to indicate the error.
  86.  
  87. SSSSEEEEEEEE AAAALLLLSSSSOOOO
  88.      exec(2), exit(2), fork(2), intro(2), pause(2), ptrace(2), sigaction(2),
  89.      signal(2), wait(2), siginfo(5)
  90.  
  91.  
  92.  
  93.  
  94.  
  95.  
  96.  
  97.  
  98.  
  99.  
  100.  
  101.  
  102.  
  103.  
  104.  
  105.  
  106.  
  107.  
  108.  
  109.  
  110.  
  111.  
  112.  
  113.  
  114.  
  115.  
  116.  
  117.  
  118.  
  119.  
  120.  
  121.  
  122.  
  123.  
  124.  
  125.  
  126.  
  127.                                                                         PPPPaaaaggggeeee 2222
  128.  
  129.  
  130.  
  131.